﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Data;
using System.ComponentModel.DataAnnotations;
using BCCommon.OAEnums;
using BCCommon.OAEnums.WorkflowActive;

namespace BCDto.OA.WorkflowActive.WorkflowActivityStep
{
	/// <summary>
	/// 工作流模板步骤
	/// </summary>
	public class WorkflowActivityStepRequestDto
	{
		/// <summary>
		/// 工作流活动Id
		/// </summary>		
		[Display(Name = "工作流活动Id")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public long WorkflowActivityId { get; set; }
		/// <summary>
		/// 工作流Code
		/// </summary>		
		[Display(Name = "工作流Code")]
		[Required(ErrorMessage = "{0} 不应为空")]
		[StringLength(50, MinimumLength = 2, ErrorMessage = "{0} 长度应大于{2} 且小于{1}")]
		public string WorkflowCode { get; set; }
		/// <summary>
		/// 工作流名称
		/// </summary>		
		[Display(Name = "工作流名称")]
		[Required(ErrorMessage = "{0} 不应为空")]
		[StringLength(100, MinimumLength = 2, ErrorMessage = "{0} 长度应大于{2} 且小于{1}")]
		public string WorkflowName { get; set; }
		/// <summary>
		/// 模板步骤Code
		/// </summary>		
		[Display(Name = "模板步骤Code")]
		[Required(ErrorMessage = "{0} 不应为空")]
		[StringLength(50, MinimumLength = 2, ErrorMessage = "{0} 长度应大于{2} 且小于{1}")]
		public string TemplateStepCode { get; set; }
		/// <summary>
		/// 步骤Code
		/// </summary>		
		[Display(Name = "步骤Code")]
		[Required(ErrorMessage = "{0} 不应为空")]
		[StringLength(50, MinimumLength = 2, ErrorMessage = "{0} 长度应大于{2} 且小于{1}")]
		public string StepCode { get; set; }
		/// <summary>
		/// 步骤名称
		/// </summary>		
		[Display(Name = "步骤名称")]
		[Required(ErrorMessage = "{0} 不应为空")]
		[StringLength(50, MinimumLength = 2, ErrorMessage = "{0} 长度应大于{2} 且小于{1}")]
		public string NodeName { get; set; }
		/// <summary>
		/// 步骤类型(开始、结束、节点、会签、条件、子流程）
		/// </summary>		
		[Display(Name = "步骤类型(开始、结束、节点、会签、条件、子流程）")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public OAStepNodeType NodeType { get; set; }
		/// <summary>
		/// 任务步骤
		/// </summary>		
		[Display(Name = "任务步骤")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public int Step { get; set; }
		/// <summary>
		/// 步骤顺序(非步骤，仅记录所有记录序列号)
		/// </summary>		
		[Display(Name = "步骤顺序(非步骤，仅记录所有记录序列号)")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public int StepOrder { get; set; }
		/// <summary>
		/// 是否为加签步骤
		/// </summary>		
		[Display(Name = "是否为加签步骤")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public bool IsAdditionalValidationStep { get; set; }
		/// <summary>
		/// 允许指定下一节点审核人
		/// </summary>
		[Display(Name = "允许指定下一节点审核人")]
		[Required(ErrorMessage = "{0} 不应为空")]
		public bool AllowAssignNextValidater { get; set; }
		/// <summary>
		/// 激活时间
		/// </summary>		
		[Display(Name = "激活时间")]
		public DateTime? ActiveTime { get; set; }
		/// <summary>
		/// 完成时间
		/// </summary>		
		[Display(Name = "完成时间")]
		public DateTime? CompleteTime { get; set; }
		/// <summary>
		/// 完成类型(通过，拒绝)
		/// </summary>		
		[Display(Name = "完成类型(通过，拒绝)")]
		public OAActivityStepCompleteType CompleteType {get;set;}
}
}

